CompleteAdding Method

Task Parallel System.Threading

Marks the BlockingCollection<(Of <(T>)>) instances as not accepting any more additions.

Namespace:  System.Collections.Concurrent
Assembly:  System.Threading (in System.Threading.dll)

Syntax

Visual Basic (Declaration)
Public Sub CompleteAdding
C#
public void CompleteAdding()

Remarks

After a collection has been marked as complete for adding, adding to the collection is not permitted and attempts to remove from the collection will not wait when the collection is empty.

Exceptions

ExceptionCondition
System..::.ObjectDisposedExceptionThe BlockingCollection<(Of <(T>)>) has been disposed.

See Also